package com.lct.d3_static_Util;

import java.util.Random;

public class LctUtlis {
    private  LctUtlis(){
    }

    //工具类都是静态方法
    public static String createCode(int n){

        String code = "";
        String data = "1234567890qwertyuiopasdfghjklzxcvbnmQAZWSXEDCRFVTGBYHNUJMIKOLP";
        Random r = new Random();

        for (int i = 0; i < n; i++) {
            int index = r.nextInt(data.length());
            char c = data.charAt(index);
            code += c;
        }
        return code;
    }
}
